class Template{
     function IncTemplate(){
          $PageSource = file_get_contents("theme/header.tpl");
          $PageSource .= file_get_contents("theme/main.tpl");
          $PageSource .= file_get_contents("theme/footer.tpl");

          $input = array("_PAGETITLE_", "_TITLE_", "_TAGLINE_");
          $output   = array($this->PageTitle(), $this->Title(), $this->TagLine());
          $PageSource = str_replace($input, $output, $PageSource);
          print $PageSource;
     }
     function PageTitle(){
          return 'IT WORKS!';
     }
     function Title(){
          return 'IT WORKS!';
     }
     function TagLine(){
          return 'IT WORKS!';
     }

     function AddContent(){

          $Page = clean_input($_GET[page]);

          switch ($Page) {
               case 'home':
               case 'main':
               default:
                    return "theme/main.tpl";
               break;
          }
     }
}